<?php
/**
 * @description:
 * @author     : Geomen
 * @time       : 2018/4/23 14:19
 */


namespace App\Http\Controllers;


use App\Role;
use Illuminate\Http\Request;

class RoleController extends Controller
{
    public function freeGet(Request $request)
    {
        if ($request->has('page')) {
            $list = Role::query()->paginate(15);
        }else{
            $list = Role::query()->get();
        }
        return response()->json(['r' => 1000, 'i' => $list]);
    }
}